﻿using System;
using System.Collections.Generic;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Data;
using System.Drawing;

public partial class RakazMenu : System.Web.UI.Page
{
    protected void Page_Load(object sender, EventArgs e)
    {
        if (Session["RakazID"] == null)
        {
            Response.Redirect("login.aspx");
        }
        else
        {
            DataSet ds = new DataSet();
            HSHDataService.HSHDataService m_data = new HSHDataService.HSHDataService();
            ds = m_data.GetOneRakazEvents((int)Session["RakazID"]);
            ds.Tables[0].Columns["EventName"].Caption="שם האירוע";
            grdEvents.DataSource = ds.Tables[0];
            grdEvents.DataBind();
            foreach (GridViewRow row in grdEvents.Rows)
            {
                if (row.Cells[4] == null)
                {
                    row.BackColor = Color.Yellow ;
                }
            }
        }
    }
}